<br/>
<table cellpadding="2" cellspacing="0" border="1" class="formTable" data-sort="sortDisabled">
    <tbody>
        <tr class="firstRow">
            <td colspan="8" class="formHead" width="1479">
                场地围堵_现场谈判处理
            </td>
        </tr>
        <tr>
            <td colspan="8" class="teamHead" width="1479">
                上报信息
            </td>
        </tr>
        <tr>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:csycdj">初始异常等级</span>:
            </td>
            <td style="width:15%;" class="formInput" width="0">
                <input type="text" el-component="1" name="m:cdwd:csycdj" class="inputText" value="" validate="{maxlength:20}"/>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp" width="126">
                <span i18nkey="m:cdwd:ycdj">异常等级</span>:
            </td>
            <td style="width:15%;" class="formInput" width="149">
                <input type="text" el-component="1" name="m:cdwd:ycdj" class="inputText" value="" validate="{maxlength:20}"/>
            </td>
            <td align="right" style="width: 10%; word-break: break-all;" class="formTitle" nowrap="nowarp"></td>
            <td style="width: 15%; word-break: break-all;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
        </tr>
        <tr>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:kssbrgh">快速上报人工号</span>:
            </td>
            <td style="width:15%;" class="formInput" width="0">
                <input type="text" el-component="1" name="m:cdwd:kssbrgh" class="inputText" value="" validate="{maxlength:100}"/>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp" width="126">
                <span i18nkey="m:cdwd:kssbrxm">快速上报人姓名</span>:
            </td>
            <td style="width:15%;" class="formInput" width="149">
                <input type="text" el-component="1" name="m:cdwd:kssbrxm" class="inputText" value="" validate="{maxlength:100}"/>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:kssbrlxfs">快速上报人联系方式</span>:
            </td>
            <td style="width:15%;" class="formInput">
                <input type="text" el-component="1" name="m:cdwd:kssbrlxfs" class="inputText" value="" validate="{maxlength:100}"/>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:kssbsj">快速上报时间</span>:
            </td>
            <td style="width:15%;" class="formInput">
                <input name="m:cdwd:kssbsj" el-component="17" type="text" class="Wdate" displaydate="0" datefmt="yyyy-MM-dd HH:mm:ss" value="" validate="{}"/>
            </td>
        </tr>
        <tr>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp" height="0">
                <span i18nkey="m:cdwd:sbrgh">上报人工号</span>:
            </td>
            <td style="width:15%;" class="formInput" width="0" height="0">
                <input type="text" el-component="1" name="m:cdwd:sbrgh" class="inputText" value="" validate="{maxlength:100}"/>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp" width="126" height="0">
                <span i18nkey="m:cdwd:sbrxm">上报人姓名</span>:
            </td>
            <td style="width:15%;" class="formInput" width="149" height="0">
                <input type="text" el-component="1" name="m:cdwd:sbrxm" class="inputText" value="" validate="{maxlength:100}"/>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp" height="0">
                <span i18nkey="m:cdwd:sbrlxfs">上报人联系方式</span>:
            </td>
            <td style="width:15%;" class="formInput" height="0">
                <input type="text" el-component="1" name="m:cdwd:sbrlxfs" class="inputText" value="" validate="{maxlength:100}"/>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp" height="0">
                <span i18nkey="m:cdwd:sbsj">上报时间</span>:
            </td>
            <td style="width:15%;" class="formInput" height="0">
                <input name="m:cdwd:sbsj" el-component="17" type="text" class="Wdate" displaydate="0" datefmt="yyyy-MM-dd HH:mm:ss" value="" validate="{}"/>
            </td>
        </tr>
        <tr>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp" height="0">
                <span i18nkey="m:cdwd:yccldq">异常处理地区</span>:
            </td>
            <td style="width: 15%; word-break: break-all;" class="formInput" height="0" width="0">
                <div>
                      
 
							<input name="m:cdwd:yccldqPATH" type="hidden" class="hidden" value=""/><input name="m:cdwd:yccldqID" type="hidden" class="hidden" value=""/><input el-component="23" selector-showfield="" name="m:cdwd:yccldq" validate="{}" readonly="" class="widget-fragment w-default" placeholder="选择..."/>
                </div>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp" height="0" width="126">
                <span i18nkey="m:cdwd:ycclwd">异常处理网点</span>:
            </td>
            <td style="width: 15%; word-break: break-all;" class="formInput" height="0" width="149">
                <div>
                      
 
							<input name="m:cdwd:ycclwdPATH" type="hidden" class="hidden" value=""/><input name="m:cdwd:ycclwdID" type="hidden" class="hidden" value=""/><input el-component="23" selector-showfield="" name="m:cdwd:ycclwd" validate="{}" readonly="" class="widget-fragment w-default" placeholder="选择..."/>
                </div>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp" height="0">
                <span i18nkey="m:cdwd:fxsj">发现时间</span>:
            </td>
            <td style="width: 15%; word-break: break-all;" class="formInput" height="0">
                <input el-component="17" name="m:cdwd:fxsj" type="text" readonly="" :default-value="1546841083772" datefmt="yyyy-MM-dd HH:mm:ss" validate="{}" class="widget-fragment w-datetimepicker"/>
            </td>
            <td align="right" style="width: 10%; word-break: break-all;" class="formTitle" nowrap="nowarp" height="0" width="141"></td>
            <td style="width: 15%; word-break: break-all;" class="formInput" height="0"></td>
        </tr>
        <tr>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:ycms">异常描述</span>:
            </td>
            <td style="width:15%;" class="formInput" width="0">
                <textarea name="m:cdwd:ycms" el-component="2" validate="{}"></textarea>
            </td>
            <td align="right" style="width: 10%; word-break: break-all;" class="formTitle" nowrap="nowarp" width="126"></td>
            <td style="width: 15%; word-break: break-all;" class="formInput" width="149"></td>
            <td style="width: 15%; word-break: break-all; text-align: right;" class="formInput">
                <span i18nkey="m:cdwd:fjxx" style="text-align: -webkit-right; white-space: normal;">附件信息</span><span style="text-align: -webkit-right; white-space: normal; background-color: rgb(250, 250, 250);">:</span>
            </td>
            <td style="width:15%;" class="formInput">
                <input type="file" value="请选择" el-component="12" name="m:cdwd:fjxx" validate="{required:false}" action="http://owsp.sit.sf-express.com/sysFile/upload" class="widget-fragment w-upload"/>
            </td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
        </tr>
        <tr>
            <td colspan="8" class="teamHead" width="1479">
                事件基本信息
            </td>
        </tr>
        <tr>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:wdcdlx">围堵场地类型</span>:
            </td>
            <td style="width:15%;" class="formInput" width="0">
                <select name="m:cdwd:wdcdlx" el-component="13" validate="{}"><option value=""></option>
                <option value="1">
                    中转场
                </option>
                <option value="3">
                    营业网点
                </option>
                <option value="5">
                    办公场地
                </option>
                <option value="7">
                    场地所在园区
                </option></select>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp" width="126">
                <span i18nkey="m:cdwd:fswd">发生网点</span>:
            </td>
            <td style="width:15%;" class="formInput" width="149">
                <input type="text" el-component="1" name="m:cdwd:fswd" class="inputText" value="" validate="{maxlength:200}"/>
            </td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
        </tr>
        <tr>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:wdfs">围堵方式</span>:
            </td>
            <td style="width:15%;" class="formInput" width="0">
                <select name="m:cdwd:wdfs" el-component="13" validate="{}"><option value=""></option>
                <option value="1">
                    人员围堵
                </option>
                <option value="3">
                    人车围堵
                </option></select>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp" width="126">
                <span i18nkey="m:cdwd:wdrs">围堵人数</span>:
            </td>
            <td style="width:15%;" class="formInput" width="149">
                <input name="m:cdwd:wdrs" type="text" el-component="1" value="" validate="{number:true,maxIntLen:20,maxDecimalLen:0}"/>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:xcsflhf">现场是否拉横幅</span>:
            </td>
            <td style="width:15%;" class="formInput">
                <select name="m:cdwd:xcsflhf" el-component="13" validate="{}"><option value=""></option>
                <option value="1">
                    是
                </option>
                <option value="3">
                    否
                </option></select>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:sfbj">是否报警</span>:
            </td>
            <td style="width:15%;" class="formInput">
                <select name="m:cdwd:sfbj" el-component="13" validate="{}"><option value=""></option>
                <option value="1">
                    是
                </option>
                <option value="3">
                    否
                </option></select>
            </td>
        </tr>
        <tr>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:wdyyms">围堵原因描述</span>:
            </td>
            <td style="width:15%;" class="formInput" colspan="3">
                <input type="text" el-component="1" name="m:cdwd:wdyyms" class="inputText" value="" validate="{maxlength:800}"/>
            </td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
        </tr>
        <tr>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:wdrysq">围堵人员诉求</span>:
            </td>
            <td style="width:15%;" class="formInput" colspan="3">
                <input type="text" el-component="1" name="m:cdwd:wdrysq" class="inputText" value="" validate="{maxlength:800}"/>
            </td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
        </tr>
        <tr id="hfnr">
            <td colspan="8" class="teamHead" style="background-color:#8ebcec;" width="676">
                回复内容
            </td>
        </tr>
        <tr>
            <td colspan="8" class="teamHead" width="1479">
                现场谈判处理
            </td>
        </tr>
        <tr>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:zdtprygh">主导谈判人员工号</span>:
            </td>
            <td style="width:15%;" class="formInput">
                <input type="text" el-component="1" name="m:cdwd:zdtprygh" class="inputText" value="" validate="{maxlength:20}"/>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:zdtpryxm">主导谈判人员姓名</span>:
            </td>
            <td style="width:15%;" class="formInput">
                <input type="text" el-component="1" name="m:cdwd:zdtpryxm" class="inputText" value="" validate="{maxlength:20}"/>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:zdtprygw">主导谈判人员岗位</span>:
            </td>
            <td style="width:15%;" class="formInput">
                <input type="text" el-component="1" name="m:cdwd:zdtprygw" class="inputText" value="" validate="{maxlength:20}"/>
            </td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
        </tr>
        <tr>
            <td class="formTitle" style="-ms-word-break: break-all;" rowspan="1" colspan="8" width="1479">
                <div type="subtable" tablename="cdwd_xctp">
                    <br/>
                    <table class="listTable">
                        <tbody>
                            <tr class="toolBar firstRow">
                                <td colspan="6" class="toolBar">
                                    <a class="link add" href="javascript:;" onclick="return false;">添加</a><span>使用右键操作</span>
                                </td>
                            </tr>
                            <tr class="headRow">
                                <th nowrap="nowarp">
                                    <span i18nkey="s:cdwd_xctp:wdrysq">围堵人员诉求</span>
                                </th>
                                <th nowrap="nowarp">
                                    <span i18nkey="s:cdwd_xctp:yyyxms">营运影响描述</span>
                                </th>
                                <th nowrap="nowarp">
                                    <span i18nkey="s:cdwd_xctp:tpjzms">谈判进展描述</span>
                                </th>
                                <th nowrap="nowarp">
                                    <span i18nkey="s:cdwd_xctp:yjlcsj">预计离场时间</span>
                                </th>
                                <th nowrap="nowarp">
                                    <span i18nkey="s:cdwd_xctp:gjrgh">跟进人工号</span>
                                </th>
                                <th nowrap="nowarp">
                                    <span i18nkey="s:cdwd_xctp:gjsj">跟进时间</span>
                                </th>
                            </tr>
                            <tr class="listRow" formtype="edit">
                                <td>
                                       
					<input type="text" el-component="1" name="s:cdwd_xctp:wdrysq" class="inputText" value="" validate="{maxlength:20,required:true}"/>
                                </td>
                                <td>
                                       
					<input type="text" el-component="1" name="s:cdwd_xctp:yyyxms" class="inputText" value="" validate="{maxlength:20,required:true}"/>
                                </td>
                                <td>
                                       
					<input type="text" el-component="1" name="s:cdwd_xctp:tpjzms" class="inputText" value="" validate="{maxlength:20,required:true}"/>
                                </td>
                                <td>
                                       
			<input name="s:cdwd_xctp:yjlcsj" el-component="17" type="text" class="Wdate" displaydate="0" datefmt="yyyy-MM-dd HH:mm:ss" value="" validate="{required:true}"/>
                                </td>
                                <td>
                                       
					<input type="text" el-component="1" name="s:cdwd_xctp:gjrgh" class="inputText" value="" validate="{maxlength:20,required:true}"/>
                                </td>
                                <td>
                                       
			<input name="s:cdwd_xctp:gjsj" el-component="17" type="text" class="Wdate" displaydate="0" datefmt="yyyy-MM-dd HH:mm:ss" value="" validate="{required:true}"/>
                                </td>
                            </tr>
                        </tbody>
                    </table><br/>
                </div>
            </td>
        </tr>
        <tr>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:tpjz">谈判进展</span>:
            </td>
            <td style="width:15%;" class="formInput">
                <select name="m:cdwd:tpjz" el-component="13" validate="{}"><option value=""></option>
                <option value="1">
                    谈判中
                </option>
                <option value="3">
                    谈判结束
                </option></select>
            </td>
            <td align="right" style="width:10%;" class="formTitle" nowrap="nowarp">
                <span i18nkey="m:cdwd:clsj">撤离时间</span>:
            </td>
            <td style="width:15%;" class="formInput">
                <input name="m:cdwd:clsj" el-component="17" type="text" class="Wdate" displaydate="0" datefmt="yyyy-MM-dd HH:mm:ss" value="" validate="{}"/>
            </td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
            <td style="width:15%;" class="formInput"></td>
        </tr>
    </tbody>
</table><br/><script>$(function(){
          //子表根据acount获取用户
          function getUser(userAccount,row){
            if(!userAccount||userAccount==''){
                return
            }
            FR.$httpExt().get(store.state.global.owspBackUrl+'sysUserManage/getUserInfo', 
				{userAccount:userAccount}).then(function(response) {
                    var result=response.result;
                    if(result.dataState!="exist"){
                        try {
                            FR.$message({
                                type: 'warning',
                                message: "用户不存在"
                            });
                        } catch (error) { 
                        }
                        row.setData('m:cdwd:zdtprygh','');
                    }else{
                        row.setData('m:cdwd:zdtpryxm',result.userName);
                        row.setData('m:cdwd:zdtprygw',result.posName);
                    }
                 }, (response) => {
                    FR.$notify.error({
                        title: '异常',
                        message: response.msg
                    });
                    row.setData('m:cdwd:zdtprygh','');
              	})            
        }
        //获取当前用户，设置跟进人工号
        function getCurrentUser(row,accountName){
            FR.$httpExt().get(store.state.global.owspBackUrl+'sysUserManage/getCurrentUser').then((response) => {
                    
                    var result=response.result;
                    if(result.dataState!="exist"){
                        try {
                            row.setData(accountName,'');
                            FR.$message({
                                type: 'warning',
                                message: "用户不存在"
                            });
                        } catch (error) { 
                        }
                    }else{
                        row.setData(accountName,result.account);
                    }
                 }, (response) => {
                    row.setData(accountName,'');
                    FR.$notify.error({
                        title: '异常',
                        message: response.msg
                    });
              	})            
        }
        //set 跟进人工号，时间
        function setaccountandtime(table,accountName,timeName){
            var rows=FR_SUB[table]||[];
            rows.forEach((row,i) => {
                if(row){
                    //获取当前用户，跟进人
                    if(!row.getData(accountName)||row.getData(accountName)==''){
                        getCurrentUser(row,accountName);
                    }
                    //获取当前时间，跟进时间
                    if(!row.getData(timeName)||row.getData(timeName)==''){
                        var date=new Date();
                        row.setData(timeName,date.getFullYear() + '-' + (date.getMonth() + 1) + '-' + date.getDate()+' '+date.getHours()+':'+date.getMinutes()+':'+date.getSeconds());
                      //row.setData(timeName,new Date());
                    }
                }
            });
        }
        //主导谈判人员姓名和岗位
        function setzdtpry(){
            var gh=FR_MAIN.getData('m:cdwd:zdtprygh');
            getUser(gh,FR_MAIN);
        }

        function init(){
            setzdtpry();
        }
        init();

        window.RowsAdd= Object.assign({}, {
            //现场谈判
			'cdwd_xctp': function(tablename, obj) {
                setaccountandtime("cdwd_xctp","s:cdwd_xctp:gjrgh","s:cdwd_xctp:gjsj");
			}
            
		});

        var fieldChange = {
            "m:cdwd:zdtprygh" : function(key, val, item, obj) {
                setzdtpry()
            },
        };
            // 表单改变
        window.FormChange = Object.assign({}, fieldChange);
        
    })</script>